namespace Tester.Views;

public partial class PersonalizePage : ContentPage
{
    public PersonalizePage()
    {
        InitializeComponent();
        this.BindingContext = new ViewModels.PersonalizeViewModels();
        Models.Message.Register(ShowMessage, "ShowDialog");
        Models.Message.Register(ShowDetailedMessage, "ShowDialog");


    }

    private async void ShowMessage(string title, string details, string button)
    {
        await DisplayAlert(title, details, button);
    }

    private async void ShowDetailedMessage(string title, string details, string accept, string cancel)
    {
        await DisplayAlert(title, details, accept, cancel);
    }

    private void themePicker_SelectedIndexChanged(object sender, EventArgs e)
    {
        var picker = (Picker)sender;
        
        int selectedIndex = picker.SelectedIndex;
        App.Current.UserAppTheme = AppTheme.Dark;

    }
}